/*!
 * @file Wave.cpp
 * @author naoki takeda
 * @version 1.0
 */
#include "StdAfx.h"
#include <windows.h>
#include <xaudio2.h>
#include <mmsystem.h>
#include "Audio/src/ManagerImpl.h"
#include "Audio/src/WaveImpl.h"


namespace NTEngine {
namespace Audio {


Wave Wave::create( const char* fileName ) {
	Wave ret;
	ret.m_Impl = NEW Impl( fileName );
	return ret;
}

Wave Wave::create( const unsigned char* data, int size, int frequency, int channelNumber ) {
	Wave ret;
	ret.m_Impl = NEW Impl( data, 16, frequency, channelNumber, size );
	return ret;
}

bool Wave::isReady() {
	return m_Impl->isReady();
}

bool Wave::isError() const {
	return m_Impl->isError();
}

#define TYPE Wave
#include "NTEngine/Base/Impl/ReferenceTypeTemplate.h"

} // namespace Audio
} // namespace NTEngine
// EOF